package com.tedu._04mybatis.pojo;

import java.util.Date;

/**
 * 我们通常在java中设计一个类用来表达数据库中的表结构，这种类被称为:实体类
 * 特点:
 * 类名与表名一致
 * 属性名与表中的字段名一致（遇到字段中出现"_"时，通常我们java中还是用驼峰命名法）
 */
public class Article {
    private Integer id;
    private String content;
    private Date created;
    private Integer userId;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public Date getCreated() {
        return created;
    }

    public void setCreated(Date created) {
        this.created = created;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    @Override
    public String toString() {
        return "Article{" +
                "id=" + id +
                ", content='" + content + '\'' +
                ", created=" + created +
                ", userId=" + userId +
                '}';
    }
}
